﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MINERP.MODEL.AutoOrder_Fuji
{
    public class JobSheetSummary_Delivery_Fuji_Info
    {

        /// <summary>
        /// 定单号，order> id
        /// </summary>
        public string Oi_OrderNum { get; set; }
        /// <summary>
        /// 开单日期 processor> date
        /// </summary>
        public DateTime Oi_OrderDate { get; set; }
        /// <summary>
        /// 用 payment> id到DB里查找
        /// </summary>
        public string Oi_PayMentName { get; set; }
        /// <summary>
        /// 用 shipping> shipping-type到DB里查找
        /// </summary>
        public string Oi_ShippingCompanyName { get; set; }


        public string OiFr_UserID { get; set; }
        public string OiFr_FamilyName { get; set; }
        public string OiFr_GivenName { get; set; }
        public string OiFr_Tel { get; set; }
        public string OiFr_MobilePhone { get; set; }


        public string DeTo_FamilyName { get; set; }
        public string DeTo_GivenName { get; set; }
        public string DeTo_MobilePhone { get; set; }
        public string CompanyName { get; set; }//发票抬头与
        /// <summary>
        ///  Address> province+city+city-part+street
        /// </summary>
        public string DeTo_Address { get; set; }


        public List<ArticleInfo> ArticleList { get; set; }

        /// <summary>
        /// 在prices original="false" result="true">段落内的shippingprice><totalprice> gross
        /// </summary>
        public decimal ShippingFee { get; set; }
        /// <summary>
        /// 在prices>result="true"的totalprice> gross
        /// </summary>
        public decimal TotalPrice { get; set; }

        #region 店的相关信息
        /// <summary>
        /// 店的地区,取loaction中的city字段
        /// </summary>
        public string ShopArea { get; set; }
        /// <summary>
        /// 店名,取company字段
        /// </summary>
        public string ShopName { get; set; }
        /// <summary>
        /// 店的地址,取street+house-number
        /// </summary>
        public string ShopAddr { get; set; }

        /// <summary>
        /// 店的电话,取phone
        /// </summary>
        public string ShopTel { get; set; }
        #endregion


    }


    public class ArticleInfo
    {
        /// <summary>
        /// order> id +"-"+ orderitem> id(*2)
        /// </summary>
        public string OrderBranch { get; set; }
        /// <summary>
        /// 用product> exportname到DB里查找 
        /// </summary>
        public string ProductName { get; set; }
        /// <summary>
        /// orderitem> quantity
        /// </summary>
        public int Quantity { get; set; }
        /// <summary>
        /// 在prices>original="true"的orderitemprice>unitprice> gross
        /// </summary>
        public decimal UnitPrice { get; set; }
        /// <summary>
        /// 初始价格（折扣前)、 在prices original="true" result="false">段落内的orderitemprice><price> gross
        /// </summary>
        public decimal TotalPriceBeforeDiscount { get; set; }
        /// <summary>
        /// 折扣价格、在prices original="false" result="false">段落内的orderitemprice><price> gross
        /// </summary>
        public decimal Discount { get; set; }
        /// <summary>
        /// 折扣后价格、在prices original="false" result="true">段落内的orderitemprice><price> gross
        /// </summary>
        public decimal TotalPriceAfterDiscount { get; set; }
    }
}
